package com.sinosoft.ebusiness.axis2client;

import java.rmi.RemoteException;

import org.apache.axis2.AxisFault;
import org.jboss.logging.Param;

import com.sinosoft.ebusiness.axis2client.CommonServiceStub.SayHello;
import com.sinosoft.ebusiness.axis2client.CommonServiceStub.SayHelloE;
import com.sinosoft.ebusiness.axis2client.CommonServiceStub.SayHelloResponse;
import com.sinosoft.ebusiness.axis2client.CommonServiceStub.SayHelloResponseE;

public class TestMain {
	public static void main(String[] args) {
		cl1();
	}
	
	public static void cl1() {
		CommonServiceStub stub;
		try {
			
			stub = new CommonServiceStub();
			SayHelloE request = new SayHelloE();
			SayHello param = new SayHello();
			param.setUserName("wuyanshen");
			request.setSayHello(param);
			SayHelloResponseE response = stub.sayHello(request);
			SayHelloResponse rep = response.getSayHelloResponse();
			
			System.out.println(rep.getString());
			
		} catch (AxisFault e1) {
			e1.printStackTrace();
		} catch (RemoteException e) {
			e.printStackTrace();
		}
	}
}
